package com.roc.template.exception;

public class BussinessException extends BaseException {
    private String errorCode = "";

    private Object data;

    @Override
    public String getErrorCode() {
        return errorCode;
    }

    @Override
    public void setErrorCode(String errorCode) {
        this.errorCode = errorCode;
    }

    public BussinessException() {
    }

    @Override
    public Object getData() {
        return data;
    }

    @Override
    public void setData(Object data) {
        this.data = data;
    }

    public BussinessException(String error, String errorCode) {
        super(error);
        this.errorCode = errorCode;
    }

    public BussinessException(String error,String errorCode, Object data) {
        super(error);
        this.errorCode = errorCode;
        this.data =  data;
    }


    public BussinessException(String error) {
        super(error);
    }

    public BussinessException(String error, Throwable cause) {
        super(error, cause);
    }

    public BussinessException(Throwable cause) {
        super(cause);
    }

    public BussinessException(String error, Throwable cause, boolean enableSuppression, boolean writableStackTrace) {
        super(error, cause, enableSuppression, writableStackTrace);
    }

}